package com.hyst.service;

import java.text.ParseException;
import java.util.List;
import java.util.Map;

import com.github.pagehelper.Page;
import com.hyst.domain.CurriculumSchedule;
import com.hyst.domain.CurriculumScheduleView;

/**
 * @Description:正式课上课表（排课表）Service
 * @author：dy 
 * @Date：2018年09月13日
 */

public interface CurriculumScheduleService {

	/**
	 * @Description: 根据条件列表查询
	 * @param curriculumSchedule
	 * @return Page<CurriculumSchedule>
	 */
	Page<CurriculumSchedule> list(CurriculumSchedule curriculumSchedule);

	/**
	 * @Description:添加单条记录，空属性值会采用数据库默认值插入
	 * @param curriculumSchedule
	 * @return CurriculumSchedule
	 */
	CurriculumSchedule insert(CurriculumSchedule curriculumSchedule);

	/**
	 * @Description:根据主键获取
	 * @param id
	 * @return CurriculumSchedule
	 */
	CurriculumScheduleView getByPriKey(Integer id);

	/**
	 * @Description:根据对象主键更新对象不为空字段
	 * @param curriculumSchedule
	 * @return CurriculumSchedule
	 */
	CurriculumSchedule updateSelective(CurriculumSchedule curriculumSchedule);

	/**
	 * @Description:根据对象主键更新对象不为空字段
	 * @param curriculumSchedule
	 * @return CurriculumSchedule
	 */
	CurriculumSchedule update(CurriculumSchedule curriculumSchedule);

	/**
	 * @Description:根据主键获取
	 * @param id
	 * @return CurriculumSchedule
	 */
	CurriculumSchedule delete(Integer id);

	/**
	* @Description: 
	* @param studentId
	* @return	Map<String,String>
	*/ 
	Map<String, String> countLastMonth(String studentId);

	List<CurriculumScheduleView> getViewByPurchaseCourse(CurriculumSchedule curriculumSchedule);
	
	List<CurriculumScheduleView>getByTeacherIdAndDate(CurriculumSchedule curriculumSchedule)throws ParseException;

	/**
	* @Description: 
	* @param curriculumSchedule
	* @return	CurriculumSchedule
	*/ 
	CurriculumSchedule add(CurriculumSchedule curriculumSchedule);

	/**
	* @Description: 
	* @param purchaseCourseId
	* @return	String
	*/ 
	String deleteByPurchaseCourseId(String purchaseCourseId);

	/**
	* @Description: 
	* @param pcid
	* @return	List<Map<String,String>>
	*/ 
	List<Map<String, String>> countByStateAndPc(String pcid);
	List<Integer> addLevalClass(final String purchaseCourseId, int length,Integer statue)
			throws ParseException, CloneNotSupportedException ;

	Boolean addClass(String picd,Integer hoursClass) throws Exception;
}
